import React from 'react';

import Search from "@/views/search";
import SearchDetail from "@/views/searchdetail";
import Read from "@/views/read"
import NotFound from "@/views/notfound"
import BookDetail from "@/views/bookdetail"
import Attention from "@/views/attention"
import {Switch, Route} from 'react-router-dom'

function App() {
  return (
    <div className="container">
      <Switch>
        {/* <Route path="/nofooter/read" exact children={(props) => {return <Read  style={{display: props.location.pathname !== '/my' ? 'none': 'block'}} ></Read>}}/> */}
        <Route path="/nofooter/read" component = {Read}/>
        <Route path="/nofooter/searchDetail" component = {SearchDetail}/>
        <Route path="/nofooter/search" component = {Search}/>
        <Route path="/nofooter/bookdetail/:_id" component = {BookDetail}/>
        <Route path="/nofooter/attention" component = {Attention}/>
       
        <Route component = {NotFound}/>
        </Switch>
    </div>
  );
}

export default App;
